sudo npm install -g typescript In ubuntu you have to add sudo at the begining to install global packages. Because sudo have the permisson to install gobal packages on ubuntu.